<?php
namespace App\Model;

use Illuminate\Database\Eloquent\Model;

class OcpcOppoLog extends Model
{
    protected $table = 'ocpc_oppo_log';
    const TYPE = [
        1=>'激活',
        2=>'注册',
        3=>'充值',
        7=>'充值'
    ];
    const IS_REG = [
        1=>'是',
        0=>'否'
    ];

    const PKG = [
        'com.xylx.wchat' => '陌玩',
        'com.chat.myu' => '陌遇',
    ];
    protected $fillable = [
        "oaid",  "imei", "pay_amount", "pkg", "res", "type", "created_at", "updated_at","user_id","is_register","package_name"
    ];

    public function userProfile()
    {
        return $this->belongsTo(UserProfile::class, 'user_id', 'user_id');
    }
}
